<template>
  <div class="father">
    <div class="content">
      <Game>
        <template v-slot="params">
          <ol>
            <li v-for="(item, index) in params.games" :key="index">
              {{ item.name }}
            </li>
          </ol>
        </template>
      </Game>
      <Game>
        <!--      解构赋值-->
        <template v-slot="{games}">
          <ul>
            <li v-for="(item, index) in games" :key="index">
              {{ item.name }}
            </li>
          </ul>
        </template>
      </Game>
      <Game>
<!--        放在默认插槽并提供数据-->
        <template v-slot:default="params">

        </template>
      </Game>
      <Game>
<!--        放在默认插槽并提供数据-->
        <template #default="params">

        </template>
      </Game>
    </div>
  </div>
</template>

<script setup lang="ts">
  import Game from "@/components/test/_16/Game.vue";
</script>

<style scoped>
.father {
  background-color: gray;
  margin: 10px;
  width: 800px;
  height: 500px;
}
.content {
  display: flex;
  flex-direction: row;
}
</style>

<script lang="ts">
  export default {
    name: "Father.vue"
  }
</script >